class GCDLCM { public static void main(String args[]) { int x, y; Scanner sc = new Scanner(System.in);
System.out.println("Enter the two numbers: "); x = sc.nextInt(); y = sc.nextInt();
System.out.println("GCD of two numbers is : " + gcd(x, y)); System.out.println("LCM of two numbers is : " + lcm(x, y)); }
static int gcd(int x, int y) { int r = 0, a, b; a = (x > y) ? x : y; // a is greater number b = (x < y) ? x : y; // b is smaller number
r = b; while (a % b != 0) { r = a % b; a = b; b = r; } return r; }
static int lcm(int x, int y) { int a; a = (x > y) ? x : y; // a is greater number while (true) { if (a % x == 0 && a % y == 0) { return a; } ++a; } } }
class GCDLCM { public static void main(String args[]) { int x, y; Scanner sc = new Scanner(System.in);
System.out.println("Enter the two numbers: "); x = sc.nextInt(); y = sc.nextInt();
System.out.println("GCD of two numbers is : " + gcd(x, y)); System.out.println("LCM of two numbers is : " + lcm(x, y)); }
static int gcd(int x, int y) { int r = 0, a, b; a = (x > y) ? x : y; // a is greater number b = (x < y) ? x : y; // b is smaller number
r = b; while (a % b != 0) { r = a % b; a = b; b = r; } return r; }
static int lcm(int x, int y) { int a; a = (x > y) ? x : y; // a is greater number while (true) { if (a % x == 0 && a % y == 0) { return a; } ++a; } } }
That strategy is the acquisition of a value-priced company by a growth company. Using the growth company's higher-priced stock for the acquisition can produce outsized revenue and earnings growth. Even better is the use of cash, particularly in a growth period when financial aggressiveness is accepted and even positively viewed.he key public rationale behind this strategy is synergy - the 1+1=3 view. In many cases, synergy does occur and is valuable. However, in other cases, particularly as the strategy gains popularity, it doesn't. Joining two different organizations, workforces and cultures is a challenge. Simply putting two separate organizations together necessarily creates disruptions and conflicts that can undermine both operations.
Telegram Auto-Delete Messages in Any Chat
Some messages arenβt supposed to last forever. There are some Telegram groups and conversations where itβs best if messages are automatically deleted in a day or a week. Hereβs how to auto-delete messages in any Telegram chat. You can enable the auto-delete feature on a per-chat basis. It works for both one-on-one conversations and group chats. Previously, you needed to use the Secret Chat feature to automatically delete messages after a set time. At the time of writing, you can choose to automatically delete messages after a day or a week. Telegram starts the timer once they are sent, not after they are read. This wonβt affect the messages that were sent before enabling the feature.